<html>
<head><meta charset="utf-8"><title>Ambiguous WF Results · wg-traits · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/index.html">wg-traits</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html">Ambiguous WF Results</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="224300762"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224300762" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> FireFighterDuck <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224300762">(Jan 28 2021 at 09:15)</a>:</h4>
<p>Would an ambiguous WF result for a TraitRef hold any specific meaning? <br>
As far as I understand it would mean that there are at least two different implementations for this TraitRef that are well formed but not equal (or at least unifyable). As WF checking happens after coherence checking, there can be at most one matching implementation. Thus, ambiguous results for a TraitRef WF goal seem to hint at other internal errors, or am I missing something here?</p>
<p>Context: The <code>wf_lowering::higher_ranked_cyclic_requirements</code> test fails for the recursive solver as it finds an ambiguous WF result. It finds these two solution substitutions: <code>[?0 := !1_0]</code> and <code>[?0 := ^0.0]</code> Both come from the same clause in the environment and should denote the same type substitution but seem to be evaluated in different contexts due to some cycles occurring.  I suspect that the problem lies somewhere in the recursive solver's usage of the inference table. I would highly appreciate it if someone else could give me a hand with figuring out if this is actually supposed to happen or where exactly things go wrong.</p>



<a name="224326409"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224326409" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224326409">(Jan 28 2021 at 13:41)</a>:</h4>
<p>I'll look at this sometime today. This is good though.</p>



<a name="224708125"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224708125" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> FireFighterDuck <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224708125">(Feb 01 2021 at 10:32)</a>:</h4>
<p><span class="user-mention" data-user-id="232957">@Jack Huey</span> Did you have an chance to look at this yet?</p>



<a name="224739475"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224739475" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224739475">(Feb 01 2021 at 15:13)</a>:</h4>
<p>Ugh I didn't. Let me look now</p>



<a name="224739879"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224739879" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224739879">(Feb 01 2021 at 15:16)</a>:</h4>
<blockquote>
<p>As far as I understand it would mean that there are at least two different implementations for this TraitRef that are well formed but not equal (or at least unifyable).</p>
</blockquote>
<p>Yes</p>



<a name="224740047"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224740047" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224740047">(Feb 01 2021 at 15:17)</a>:</h4>
<blockquote>
<p>As WF checking happens after coherence checking, there can be at most one matching implementation.</p>
</blockquote>
<p>Well, in the chalk test suite, they're lumped together, sort of</p>



<a name="224740141"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224740141" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224740141">(Feb 01 2021 at 15:18)</a>:</h4>
<p>I don't think we "actually" have WF checks</p>



<a name="224740180"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224740180" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224740180">(Feb 01 2021 at 15:18)</a>:</h4>
<p>err, we do</p>



<a name="224740302"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224740302" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224740302">(Feb 01 2021 at 15:19)</a>:</h4>
<blockquote>
<p>Thus, ambiguous results for a TraitRef WF goal seem to hint at other internal errors, or am I missing something here?</p>
</blockquote>
<p>Well...probably, yes</p>



<a name="224740385"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224740385" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224740385">(Feb 01 2021 at 15:20)</a>:</h4>
<blockquote>
<p>The wf_lowering::higher_ranked_cyclic_requirements test fails for the recursive solver as it finds an ambiguous WF result. It finds these two solution substitutions: [?0 := !1_0] and [?0 := ^0.0] Both come from the same clause in the environment and should denote the same type substitution but seem to be evaluated in different contexts due to some cycles occurring.</p>
</blockquote>
<p>Looking at this now</p>



<a name="224740646"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224740646" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> FireFighterDuck <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224740646">(Feb 01 2021 at 15:22)</a>:</h4>
<p><span class="user-mention silent" data-user-id="232957">Jack Huey</span> <a href="#narrow/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results/near/224740385">said</a>:</p>
<blockquote>
<blockquote>
<p>The wf_lowering::higher_ranked_cyclic_requirements test fails for the recursive solver as it finds an ambiguous WF result. It finds these two solution substitutions: [?0 := !1_0] and [?0 := ^0.0] Both come from the same clause in the environment and should denote the same type substitution but seem to be evaluated in different contexts due to some cycles occurring.</p>
</blockquote>
<p>Looking at this now</p>
</blockquote>
<p>To be more specific, it happens in the third part of the test and only for the <code>impl&lt;T,U&gt; Bar...</code>.</p>



<a name="224740946"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224740946" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224740946">(Feb 01 2021 at 15:23)</a>:</h4>
<p>weird...uh...it's working for me locally</p>



<a name="224741056"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224741056" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224741056">(Feb 01 2021 at 15:24)</a>:</h4>
<p>Let me pull latest master and double check</p>



<a name="224741447"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224741447" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224741447">(Feb 01 2021 at 15:26)</a>:</h4>
<p>I wonder if this was variance related bug that got fixed recently?</p>



<a name="224741529"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224741529" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224741529">(Feb 01 2021 at 15:27)</a>:</h4>
<p>My list of failures with current master:</p>
<div class="codehilite"><pre><span></span><code>    test::cycle::overflow
    test::lifetimes::empty_outlives
    test::lifetimes::erased_outlives
    test::lifetimes::static_outlives
    test::misc::lifetime_outlives_constraints
    test::misc::subgoal_abstraction
    test::misc::subgoal_cycle_inhabited
    test::misc::subgoal_cycle_uninhabited
    test::misc::type_outlives_constraints
</code></pre></div>



<a name="224741932"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224741932" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224741932">(Feb 01 2021 at 15:29)</a>:</h4>
<p>I think that's simultaneously the best feeling and the worst feeling: when a bug you've seen is just fixed in the latest code</p>



<a name="224741957"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224741957" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> FireFighterDuck <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224741957">(Feb 01 2021 at 15:29)</a>:</h4>
<p>I probably should have mentioned that I run the WF checks with the recursive solver as part of working on <a href="https://github.com/rust-lang/chalk/issues/587">chalk#587</a> . To be more specific, I changed the used solver in the <code>lowering_success</code> macro to recursive_default. . With this I can reproduce the failure on latest master.</p>



<a name="224742042"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224742042" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224742042">(Feb 01 2021 at 15:30)</a>:</h4>
<p>:O</p>



<a name="224742091"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224742091" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224742091">(Feb 01 2021 at 15:30)</a>:</h4>
<p>oof I see</p>



<a name="224742134"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224742134" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224742134">(Feb 01 2021 at 15:30)</a>:</h4>
<p>I only changed it in <code>test/mod</code></p>



<a name="224742402"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224742402" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224742402">(Feb 01 2021 at 15:32)</a>:</h4>
<p>yep, there we go</p>



<a name="224742409"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224742409" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224742409">(Feb 01 2021 at 15:32)</a>:</h4>
<p>Thanks for that :)</p>



<a name="224742422"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224742422" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224742422">(Feb 01 2021 at 15:32)</a>:</h4>
<p>One sec, looking...</p>



<a name="224748509"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224748509" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224748509">(Feb 01 2021 at 16:06)</a>:</h4>
<p>the recursive needs a debug output makeover</p>



<a name="224757632"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224757632" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Areredify <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224757632">(Feb 01 2021 at 17:04)</a>:</h4>
<p>I can jump on that</p>



<a name="224757745"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224757745" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224757745">(Feb 01 2021 at 17:04)</a>:</h4>
<p>That would be awesome, actually. I'm trying to go through the debug output and just...not getting very far</p>



<a name="224757906"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224757906" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224757906">(Feb 01 2021 at 17:05)</a>:</h4>
<p>Also, anyone know if there's a way to disable a specific span in <code>tracing</code> while keeping everything else <code>debug</code></p>



<a name="224758011"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224758011" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224758011">(Feb 01 2021 at 17:06)</a>:</h4>
<p>I tried <code>CHALK_DEBUG=[program_clauses_for_env]=info,debug</code>, but that doesn't do what I want (hide everything under <code>program_clauses_for_env</code>)</p>



<a name="224758423"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224758423" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224758423">(Feb 01 2021 at 17:09)</a>:</h4>
<p>Here is a slightly cleaned up debug output for anyone looking (and for me later): <a href="https://gist.github.com/jackh726/36a6ee16cb250e630b809cd4b27629e9">https://gist.github.com/jackh726/36a6ee16cb250e630b809cd4b27629e9</a></p>



<a name="224759011"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224759011" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> FireFighterDuck <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224759011">(Feb 01 2021 at 17:12)</a>:</h4>
<p><span class="user-mention silent" data-user-id="232957">Jack Huey</span> <a href="#narrow/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results/near/224758423">said</a>:</p>
<blockquote>
<p>Here is a slightly cleaned up debug output for anyone looking (and for me later): <a href="https://gist.github.com/jackh726/36a6ee16cb250e630b809cd4b27629e9">https://gist.github.com/jackh726/36a6ee16cb250e630b809cd4b27629e9</a></p>
</blockquote>
<p>The actually interesting part start around line 4860.</p>



<a name="224759594"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224759594" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224759594">(Feb 01 2021 at 17:16)</a>:</h4>
<p>I edited it to make it shorter,  I think from there</p>



<a name="224761047"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224761047" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> FireFighterDuck <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224761047">(Feb 01 2021 at 17:25)</a>:</h4>
<p>I'll try sketching out what's going (i.e. what goals occur):</p>
<ul>
<li>WellFormed(!1_1: Bar&lt;!1_0&gt;)</li>
<li>Implemented(!1_1: Bar&lt;!1_0&gt;)</li>
<li>FromEnv(!1_1: Bar&lt;!1_0&gt;)</li>
<li>FromEnv(!1_1: Foo&lt;^0.0&gt;) (From the clause <code>FromEnv(^0.0: Bar&lt;^0.2&gt;) :- FromEnv(^0.0: Foo&lt;^0.1&gt;)</code> where we obviously do not know ^0.1)</li>
<li>FromEnv(!1_1: Bar&lt;^0.0&gt;)</li>
<li>FromEnv(!1_1: Foo&lt;^0.0&gt;) again, the computation stops as this is a cycle</li>
<li>It returns to the first occurance and tries <code>FromEnv(!1_1: Foo&lt;!1_0&gt;)</code> which obviously works</li>
<li>the cycle gets rolled back, we have the first solution <code>[?0 := !1_0]</code></li>
</ul>



<a name="224761832"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/Ambiguous%20WF%20Results/near/224761832" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> FireFighterDuck <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/Ambiguous.20WF.20Results.html#224761832">(Feb 01 2021 at 17:31)</a>:</h4>
<p>It then goes on like this:</p>
<ul>
<li>FromEnv(!1_1: Bar&lt;^0.0&gt;)</li>
<li>FromEnv(!1_1: Foo&lt;^0.0&gt;) again a cycle</li>
<li>it takes the current solution <code>[?0 := !1_0]</code> and somehow ends up creating <code>[?0 := ^0.0]</code></li>
<li>it somehow again finds the solution  <code>[?0 := !1_0]</code> (I'm not really sure what happens here)</li>
<li>the new solution gets pushed up and is combined with the old one =&gt; ambiguous (and this result doesn't change any more)</li>
</ul>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>